package com.hxzy.service.impl;

import com.hxzy.bean.User;
import com.hxzy.dao.UserDao;
import com.hxzy.dao.impl.UserDaoImpl;
import com.hxzy.service.UserService;

import java.util.List;

/**
 * @author nick
 */
public class UserServiceImpl implements UserService {
    private UserDao userDao = new UserDaoImpl();

    @Override
    public int save(User user) {
        return userDao.save(user);
    }

    @Override
    public int update(User user) {
        return userDao.update(user);
    }

    @Override
    public int remove(Integer integer) {
        return userDao.remove(integer);
    }

    @Override
    public List<User> queryAll() {
        return userDao.queryAll();
    }

    @Override
    public User findById(Integer integer) {
        return userDao.findById(integer);
    }

    @Override
    public User findByAccount(String account) {
        return userDao.findByAccount(account);
    }
}
